<script type="text/javascript">
    $(document).ready(function(){
          $("#read-more-vn").click(function(){
            if($("#tvs-vn").css('display') == 'block'){
                $("#tvs-vn").css('display','none');
                $("#read-more-vn").text("Xem thêm »");
            }else{
                $("#tvs-vn").css('display','block');
                $("#read-more-vn").text("Rút gọn »");
            }    
          });
          $("#read-more-qt").click(function(){
            if($("#tvs-qt").css('display') == 'block'){
                $("#tvs-qt").css('display','none');
                $("#read-more-qt").text("Xem thêm »");
            }else{
                $("#tvs-qt").css('display','block');
                $("#read-more-qt").text("Rút gọn »");
            }    
          });
    })
</script>

<script type="text/javascript">

  var _gaq = _gaq || [];
  _gaq.push(['_setAccount', 'UA-38591031-1']);
  _gaq.push(['_trackPageview']);

  (function() {
    var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
    ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
  })();

</script>

<?php 
    $link = $this->link;
    $ModelR = new RemoveCircumflex();
?>
<div class="main-content">
    <div class="play-tv">
        <?php $tv = $this->tv;?>
        <h2><?php echo $tv['name']?></h2>
        <span><?php echo $tv['code_mobile']?></span>
    </div>
    
    <div class="tv-dif">
        <div class="tv-dif-vn tvs-vn-block">
            <h2 class="content-block-title">Việt Nam <a id="read-more-vn" class="read-more-type">Rút gọn »</a></h2>
            <div id="tvs-vn">
                <?php foreach($this->tvs_dif_vn as $item){ if($item['code_mobile'] != ''){?>
                    <a href="/app/truyen-hinh-online/<?php echo $item['id']?>-<?php echo $ModelR->rewrite($item['name']);?>.html"><img src="<?php echo $item['logo']?>"/></a>
                <?php }}?>
            </div>
        </div>
        <div class="tv-dif-qt tvs-qt-block">
            <h2 class="content-block-title">Quốc tế <a id="read-more-qt" class="read-more-type">Rút gọn »</a></h2>
            <div id="tvs-qt">
                <?php foreach($this->tvs_dif_qt as $item){ if($item['code_mobile'] != ''){?>
                    <a href="/app/truyen-hinh-online/<?php echo $item['id']?>-<?php echo $ModelR->rewrite($item['name']);?>.html"><img src="<?php echo $item['logo']?>"/></a>
                <?php }}?>
            </div>
        </div>
    </div>
</div>